<!doctype html>
<!--[if IE 7 ]>    <html lang="en" class="no-js ie7"> <![endif]-->
<!--[if IE 8 ]>    <html lang="en" class="no-js ie8"> <![endif]-->
<!--[if IE 9 ]>    <html lang="en" class="no-js ie9"> <![endif]-->
<!--[if (gt IE 9)|!(IE)]><!--> <html lang="en" class="no-js"> <!--<![endif]-->
<head>
<?php use_helper('I18N') ?>
<?php include('scripts.php'); ?>

<!-- CSS Styles -->
<link rel="stylesheet" href="/css/style.css">
<link rel="stylesheet" href="/css/colors.css">

<!-- Google WebFonts -->
<link href='http://fonts.googleapis.com/css?family=PT+Sans:regular,italic,bold,bolditalic' rel='stylesheet' type='text/css'>
<style type="text/css">
    .redbutton {
        background:#ae432e url('/images/btns/btn_red.png') repeat-x left top;
    }
    body {
        line-height: 1;
        font-family:Arial, Helvetica, sans-serif; background:#E6E6E6 url(/images/login/main_bg.jpg) no-repeat top center; font-size:12px; color:#666;
    }
</style>
<script>
$(function() {
    $("#lang").change(function() {
        $("#langForm").submit();
    });

    $("#registerForm").validate({
        messages : {

        },
        rules : {
            "username" : {
                required : true
            },
            "email" : {
                required : true
                , email: true
            }
        },
        submitHandler: function(form) {
            form.submit();
        },
        success: function(label) {
            //label.addClass("valid").text("Valid captcha!")
        }
    });
});

function waiting() {
    $("#waitingLB h3").html("<h3>Loading...</h3><div id='loader' class='loader'><img id='img-loader' src='/images/loading.gif' alt='Loading'/></div>");

    $.blockUI({
        message: $("#waitingLB")
            , css: {
                border: 'none',
                padding: '5px',
                'background-color': '#fff',
                '-webkit-border-radius': '10px',
                '-moz-border-radius': '10px',
                'border-radius': '10px',
                opacity: .8,
                color: '#000'
    }});
    $(".blockOverlay").css("z-index", 1010);
    $(".blockPage").css("z-index", 1011);
}
function alert(data) {
    var msgs = "";
    if ($.isArray(data)) {
        jQuery.each(data, function(key, value) {
            msgs = value + "<br>";
        });
    } else {
        msgs = data + "<br>";
    }

    var alertPanel = "<div style='margin-bottom: 20px; padding: 0 .7em;' class='ui-state-highlight ui-corner-all'><p><span style='float: left; margin-right: .3em;' class='ui-icon ui-icon-info'></span>";
    alertPanel += msgs +"</p></div>";
    $("#waitingLB h3").html(alertPanel);
    $.blockUI({
        message: $("#waitingLB")
            , css: {
                border: 'none',
                padding: '5px',
                '-webkit-border-radius': '10px',
                '-moz-border-radius': '10px',
                'border-radius': '10px',
                opacity: .9
    }});
    $(".blockOverlay").css("z-index", 1010);
    $(".blockPage").css("z-index", 1011);
    $('.blockOverlay').attr('title','Click to unblock').click($.unblockUI);
}
</script>
</head>
<body>
<div id="waitingLB" style="display:none; cursor: default">
    <h3>We are processing your request.  Please be patient.</h3>
</div>
    <div style="margin-left: 200px; padding: 10px"><img src="/images/login/logo.png" alt="Maplegolds"></div>
	<section role="main" style="box-shadow: 0 0 5px #999999;">
		<!-- Login box -->
		<article class="full-block clearfix">

			<div class="article-container">

				<h3 style="font-size: 153.9%;"><?php echo __('Forget Password') ?></h3>

                <div style="position: fixed; right: 100px; top: 10px">
                    <form method="post" action="/home/language" id="langForm" name="langForm">
                    <select name="lang" id="lang">
                        <option value="en"
                                <?php
                                    if ($sf_user->getCulture() == "en")
                                        echo 'selected'
                                ?>
                        >English</option>
                        <option value="cn"
                                <?php
                                    if ($sf_user->getCulture() == "cn")
                                        echo 'selected'
                                ?>
                                >中文</option>
                    </select>
                    </form>
                </div>

				<form action="/member/forgetPassword" id="registerForm" method="post">
					<fieldset>
						<dl>
                            <dt>
								<label><?php echo __('User Name') ?></label>
							</dt>
							<dd>
								<input name="username" type="text" id="username" class="login_t73" value="<?php echo $username ?>"/>
							</dd>
							<dt>
								<label><?php echo __('Email') ?></label>
							</dt>
							<dd>
								<input name="email" type="text" id="email" class="login_t73" value="<?php echo $email ?>"/>
							</dd>
						</dl>
					</fieldset>
                    <?php if ($sf_flash->has('errorMsg')) { ?>
                        <div class="notification error">
                            <p><strong><?php echo $sf_flash->get('errorMsg') ?></strong></p>
                        </div>
                    <?php } elseif ($sf_flash->has('successMsg')) {  ?>
                        <div class="notification success">
                            <p><strong><?php echo $sf_flash->get('successMsg') ?></strong></p>
                        </div>
                    <?php } ?>
                    <br>
					<button type="submit" class="right redbutton" id="btnRegister"><?php echo __('Send') ?></button>
				</form>

			</div>

		</article>

	</section>
</body>
</html>